package test4;

import java.util.Scanner;

public class CarTest {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        Car[] arr = new Car[3];
        for (int i = 0; i < 3; i++) {
            System.out.println("请输入第"+(i+1)+"款汽车品牌/价格/颜色");
            String brand = sc.nextLine();
            double price = sc.nextDouble();
            String color = sc.nextLine();
            arr[i] = new Car(brand,price,color);
        }
        for (int i = 0; i < 3; i++) {
            Car arr1 = arr[i];
            System.out.println(arr1.getBrand()+","+arr1.getPrice()+","+arr1.getColor());
        }
    }
}
